import request from "@/utils/request";

/**
 *
 * 获取医院列表
 */
export function getHospitalListAPI(query) {
  return request({
    url: "/zpMedical/org/medicalList",
    method: "get",
    params: query,
  });
}
/** 获取医生详情 */
export function getDoctorDetailAPI(query) {
  return request({
    url: `/medical/physician/getPhysicianById`,
    method: "get",
    params: query,
  });
}
/** 获取护士详情 */
export function getNurseDetailAPI(query) {
  return request({
    url: `/medical/nurse/getNurseById`,
    method: "get",
    params: query,
  });
}
/** 获取医院详情 */
export function getHospitalDetailAPI(query) {
  return request({
    url: `/zpMedical/org/getInfo`,
    method: "get",
    params: query,
  });
}

/** 新增医院  */
export function addHospitalAPI(query) {
  return request({
    url: "/zpMedical/org/add",
    method: "post",
    data: query,
  });
}
/** 获取备案状态  */
export function getRecordAPI(query) {
  return request({
    url: "/zpMedical/org/getRecordStatus",
    method: "get",
    params: query,
  });
}

/** 获取许可证状态  */
export function getLicenseAPI(query) {
  return request({
    url: "/zpMedical/org/getMedicalLicenseStatus",
    method: "get",
    params: query,
  });
}
/** 机构自查自纠列表 */
export function getInspectionListAPI(query) {
  return request({
    url: "/zpSelf/examination/list",
    method: "get",
    params: query,
  });
}
/** 机构自查自纠详情 */
export function getInspectionDetailAPI(query) {
  return request({
    url: `/zpSelfExamination/detail/getListById`,
    method: "get",
    params: query,
  });
}
/** 处方权限授权列表 */
export function getAuthListAPI(query) {
  return request({
    url: `/medical/medicalAuth/list`,
    method: "get",
    params: query,
  });
}
/** 获取企业人员列表 */
export function getEnterprisePersonListAPI(query) {
  return request({
    url: `/zpMedical/org/getStaffListByCode`,
    method: "get",
    params: query,
  });
}


// 查询检查机任务信息列表
export function getInspectTaskListAPI(query) {
  return request({
    url: '/zp/taskInfo/inspectList',
    method: 'get',
    params: query
  })
}
/**
 *
 * 获取双随机列表
 */
export function getDoubleRandomListAPI(query) {
  return request({
      url: '/zp/taskInfo/doubleRandomList',
      method: 'get',
      params: query
    })
}

// 查询抽查机任务信息列表
export function getSpotInspectListAPI(query) {
  return request({
    url: '/zp/taskInfo/spotCheckList',
    method: 'get',
    params: query
  })
}
/** 获取文书列表 */
export function getHospitalDocumentListAPI(query) {
  return request({
    url: '/medical/administrativeSanction/getListByCreditCode',
    method: 'get',
    params: query
  })
}
/** 刷新资格证 */
export function refreshQualificationAPI(query) {
  return request({
    url: '/zpMedical/org/updateStaffInfo',
    method: 'post',
    data: query
  })
}
/** 医师执行地点查询 */
export function getDoctorExecutePlaceAPI(query) {
  return request({
    url: '/medical/location/list',
    method: 'get',
    params: query
  })
}
/** 单位变更记录查询 */
export function getUnitChangeRecordAPI(query) {
  return request({
    url: '/medical/medicalChange/list',
    method: 'get',
    params: query
  })
}
